package com.wzy.mapper;

import com.wzy.entity.Blog;
import com.wzy.entity.Violence;
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import org.apache.ibatis.annotations.Param;

import java.util.List;

/**
 * <p>
 * Mapper 接口
 * </p>
 *
 * @author wzy
 * @since 2021-02-09
 */
public interface ViolenceMapper extends BaseMapper<Violence> {

    /**
     * 查找没有新增过的暴行
     * @return 暴行集合
     */
    public List<Violence> selectNotAppend();








    public boolean inserts(Violence violence);

    public boolean delete(Long violenceId);

    public boolean update(Violence violence);

    public Violence selectById(Long violenceId);

    /**
     * 查找暴行列表
     * @param skip
     * @param take
     * @return
     */
    public List<Violence> selectbytime(@Param("skip") Integer skip, @Param("take") Integer take);

    /**
     * 查找暴行记录数
     * @return
     */
    public int size();

    public List<Violence> selectByCondition(@Param("condition") Violence condition,@Param("skip") Integer skip,@Param("take") Integer take);

    public int sizeByCondition(@Param("condition") Violence condition);

    Blog selectViolenceDetailById(String violenceId);
}
